//
//  MessageBubbleView.m
//  BaiTengIM
//
//  Created by awh on 2019/6/29.
//  Copyright © 2019 awh. All rights reserved.
//

#import "MessageBubbleView.h"

@implementation MessageBubbleView

- (instancetype)initWithDirection:(MessageDirection)messageDirection type:(MessageType)messageType {
    self = [super init];
    if (self) {
        self.userInteractionEnabled = YES;
        _messageDirection = messageDirection;
        _messageType = messageType;
    }
    return self;

}

- (void)setupBubbleBackgroundImage {
    if (self.messageDirection == MessageDirectionSend) {
        self.image = [[UIImage imageNamed:@"list_lt_kuang"] stretchableImageWithLeftCapWidth:15 topCapHeight:15];
    } else {
        self.image = [[UIImage imageNamed:@"list_lt_kuangbai"] stretchableImageWithLeftCapWidth:15 topCapHeight:15];
    }

}
@end
